home *** CD-ROM | disk | FTP | other *** search
Text File | 1990-04-08 | 53.0 KB | 1,722 lines |
- This is patch #1 to Moira release 2.2, of Mon Apr 9 22:09:38 EDT 1990
-
- BE SURE TO APPLY THIS PATCH WITH
-
- patch -p
-
- TO PRESERVE THE DIRECTORY HIERARCHY.
-
- The following bugs are fixed:
-
- 1. create patchlevel.h
- 2. Problem with "make install" on top level directory.
- 3. Typecheck filesystem access flags from the database.
- 4. Improved error message from the dcm when a generator fails.
- 5. Only use optimized malloc with Ingres version 5 on a vax.
- 6. The no-host placeholder [NONE] failed to survive the hostname
- canonicalization routine.
- 7. Allow mrtest to take a command from the Unix command line.
- 8. Improved error reporting for missing Ingres range statements.
- 9. Don't report false authentication errors when the database is
- unavailable because of deadlock or timeout.
- 10. Don't allow multiple users with the same encrypted ID number.
- 11. Make sure the quota information is handled correctly when a
- filesystem type is changed.
- 12. Allow the register_user query to work on users in state 6.
- 13. Improve authentication error message from blanche.
- 14. A number of typos are fixed in error messages in chfn.
- 15. If someone started userreg who was in half-enrolled state, he
- would never be successful in registering.
- 16. Sometimes userreg would immediately clear the screen after
- printing an error message.
- 17. Userreg sometimes incorrectly capitalized someone's middle name.
- 18. Userreg couldn't decode kerberos and some Moira errors.
- 19. The default path for the script when creating a new service entry
- in moira was wrong.
- 20. Allow more of commands to moira client to be specified on the
- command line before being prompted.
-
- Be sure to set INGRESVER correctly in include/moira_site.h before
- recompiling your sources.
-
-
-
- *** /dev/null Mon Apr 9 17:05:09 1990
- --- patchlevel.h Mon Apr 9 21:02:13 1990
- ***************
- *** 0 ****
- --- 1 ----
- + #define PATCHLEVEL 1
- *** /site/mar/moira/Makefile Mon Mar 19 21:45:03 1990
- --- Makefile Fri Mar 30 17:30:25 1990
- ***************
- *** 1,7 ****
- # Makefile for SMS 2.0
- #
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v 1.13 90/03/19 21:44:56 mar Exp $
- # $Author: mar $
- #
- # (c) Copyright 1988 by the Massachusetts Institute of Technology.
- --- 1,7 ----
- # Makefile for SMS 2.0
- #
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/RCS/Makefile,v 1.14 90/03/30 17:30:21 mar Exp $
- # $Author: mar $
- #
- # (c) Copyright 1988 by the Massachusetts Institute of Technology.
- ***************
- *** 25,31 ****
- (cd $$i; make ${MFLAGS} all); done
-
- install:
- ! if [ ! -d bin ] then; mkdir bin; fi \
- if [ -f /usr/rtingres/bin/eqc ]; then \
- DIRS="${ALLDIRS} ${INSTALLDIRS}" ; \
- else \
- --- 25,33 ----
- (cd $$i; make ${MFLAGS} all); done
-
- install:
- ! if [ ! -d bin ]; then \
- ! mkdir bin ; \
- ! fi; \
- if [ -f /usr/rtingres/bin/eqc ]; then \
- DIRS="${ALLDIRS} ${INSTALLDIRS}" ; \
- else \
- ***************
- *** 32,38 ****
- DIRS="${RTDIRS} ${INSTALLDIRS}" ; \
- fi; \
- for i in $$DIRS; do \
- ! (cd $$i; make ${MFLAGS} DESTDIR=${DESTDIR} install); done
-
- world:
- make clean
- --- 34,41 ----
- DIRS="${RTDIRS} ${INSTALLDIRS}" ; \
- fi; \
- for i in $$DIRS; do \
- ! (cd $$i; make ${MFLAGS} DESTDIR=${DESTDIR} install); \
- ! done
-
- world:
- make clean
- *** /site/mar/moira/db/newmoira.qc Fri Mar 23 12:25:10 1990
- --- db/newmoira.qc Fri Apr 6 12:57:25 1990
- ***************
- *** 1,4 ****
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/db/RCS/newmoira.qc,v 1.13 90/03/23 12:24:27 mar Exp $
- *
- * Creates a new sms database
- *
- --- 1,4 ----
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/db/RCS/newmoira.qc,v 1.15 90/04/06 12:57:04 mar Exp $
- *
- * Creates a new sms database
- *
- ***************
- *** 54,59 ****
- --- 54,66 ----
- {"filesys", "TYPE", "NFS"},
- {"filesys", "TYPE", "RVD"},
- {"filesys", "TYPE", "AFS"},
- + {"fs_access_AFS", "TYPE", "w"},
- + {"fs_access_AFS", "TYPE", "n"},
- + {"fs_access_NFS", "TYPE", "r"},
- + {"fs_access_NFS", "TYPE", "n"},
- + {"fs_access_NFS", "TYPE", "w"},
- + {"fs_access_RVD", "TYPE", "r"},
- + {"fs_access_RVD", "TYPE", "x"},
- {"gaus", "TYPE", "LIST"},
- {"gaus", "TYPE", "USER"},
- {"gaus", "TYPE", "RLIST"},
- *** /site/mar/moira/dcm/dcm.c Mon Mar 19 18:52:49 1990
- --- dcm/dcm.c Mon Apr 9 18:42:10 1990
- ***************
- *** 7,17 ****
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.13 90/03/19 18:52:46 mar Exp $
- */
-
- #ifndef lint
- ! static char rcsid_dcm_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.13 90/03/19 18:52:46 mar Exp $";
- #endif lint
-
- #include <stdio.h>
- --- 7,17 ----
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.14 90/04/09 18:41:45 mar Exp $
- */
-
- #ifndef lint
- ! static char rcsid_dcm_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/dcm/RCS/dcm.c,v 1.14 90/04/09 18:41:45 mar Exp $";
- #endif lint
-
- #include <stdio.h>
- ***************
- *** 219,225 ****
- waits.w_status = system(dfgen_cmd);
- signal(SIGCHLD, cstat);
- if (waits.w_termsig) {
- ! status = MR_TAR_FAIL;
- com_err(whoami, status, " %s exited on signal %d",
- dfgen_prog, waits.w_termsig);
- } else if (waits.w_retcode) {
- --- 219,225 ----
- waits.w_status = system(dfgen_cmd);
- signal(SIGCHLD, cstat);
- if (waits.w_termsig) {
- ! status = MR_COREDUMP;
- com_err(whoami, status, " %s exited on signal %d",
- dfgen_prog, waits.w_termsig);
- } else if (waits.w_retcode) {
- *** /site/mar/moira/include/moira_site.h Sat Mar 17 16:31:18 1990
- --- include/moira_site.h Wed Apr 4 11:30:53 1990
- ***************
- *** 12,18 ****
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v 1.17 90/03/17 16:31:12 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- --- 12,18 ----
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/include/RCS/moira_site.h,v 1.18 90/04/04 11:30:27 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- ***************
- *** 37,42 ****
- --- 37,44 ----
- /* #define SYSLOG */
- /* Athena local hacks -- other sites probably don't want this */
- #define ATHENA
- + /* Ingres version number */
- + #define INGRESVER 5
-
-
- #define NAME 0
- *** /site/mar/moira/rpc/mr_et.et Sat Mar 17 16:37:44 1990
- --- rpc/mr_et.et Mon Apr 9 19:21:20 1990
- ***************
- *** 1,6 ****
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v $
- # $Author: mar $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v 1.14 90/03/17 16:37:37 mar Exp $
- #
- error_table sms
-
- --- 1,6 ----
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v $
- # $Author: mar $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/mr_et.et,v 1.16 90/04/09 19:21:13 mar Exp $
- #
- error_table sms
-
- ***************
- *** 200,204 ****
- --- 200,210 ----
-
- ec MR_LISTLOOP,
- "Lists are not allowed to contain themselves as members"
- +
- + ec MR_INGRES_SOFTFAIL,
- + "Temporary database failure, try again"
- +
- + ec MR_COREDUMP,
- + "Subprocess coredumped"
-
- end
- *** /site/mar/moira/rpc/fixhost.c Thu Mar 22 15:27:10 1990
- --- rpc/fixhost.c Thu Apr 5 17:45:22 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.7 90/03/17 00:35:05 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.8 90/04/05 17:45:11 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- ***************
- *** 9,15 ****
- */
-
- #ifndef lint
- ! static char *rcsid_fixhost_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.7 90/03/17 00:35:05 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 9,15 ----
- */
-
- #ifndef lint
- ! static char *rcsid_fixhost_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/rpc/RCS/fixhost.c,v 1.8 90/04/05 17:45:11 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 59,65 ****
- return(strsave(tbuf));
- }
-
- ! if (index(host, '*') || index(host, '?'))
- return(host);
-
- hp = gethostbyname(host);
- --- 59,65 ----
- return(strsave(tbuf));
- }
-
- ! if (index(host, '*') || index(host, '?') || index(host, '['))
- return(host);
-
- hp = gethostbyname(host);
- *** /site/mar/moira/test/test.c Sat Mar 17 17:26:08 1990
- --- test/test.c Mon Apr 9 15:02:43 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.19 90/03/17 17:26:01 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.20 90/04/09 15:02:25 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- ***************
- *** 10,16 ****
- */
-
- #ifndef lint
- ! static char *rcsid_test_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.19 90/03/17 17:26:01 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 10,16 ----
- */
-
- #ifndef lint
- ! static char *rcsid_test_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/test/RCS/test.c,v 1.20 90/04/09 15:02:25 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 49,54 ****
- --- 49,58 ----
- if (status != 0) {
- com_err(whoami, status, "Unable to create invocation");
- exit(1);
- + }
- + if (argc > 1) {
- + argv++;
- + ss_execute_command(ss, argv);
- }
- ss_listen(ss, &status);
- if (status != 0) {
- *** /site/mar/moira/server/mr_smalloc.c Mon Mar 19 15:46:22 1990
- --- server/mr_smalloc.c Fri Apr 6 17:09:35 1990
- ***************
- *** 148,153 ****
- --- 148,154 ----
- #include <sys/time.h>
- #include <sys/resource.h>
- #endif /* BSD42 */
- + #include <moira_site.h>
-
- #ifdef scribblecheck
- #define rcheck
- ***************
- *** 283,291 ****
- --- 284,298 ----
- {
- return(((struct mhead *)a_block-1)->mh_nbytes);
- }
- +
- + #if INGRESVER == 5 && defined(vax)
- + /* This is here to pull in our private version of meinitlst.o
- + * so that we don't try to get the buggy Ingres 5.0 one.
- + */
- extern int MEinitLists();
-
- static int (*foo)() = MEinitLists;
- + #endif
-
-
- /****************************************************************
- ***************
- *** 361,376 ****
- nblks = 1;
- if ((siz = nu) < 8)
- nblks = 1 << ((siz = 8) - nu);
- ! #ifdef notdef
- ! if ((cp = sbrk (1 << (siz + 3))) == (char *) -1)
- ! return; /* no more room! */
- ! #endif notdef
- {
- ! char *tcp;
- ! if (MEalloc(1, 1 << (siz+3), &tcp))
- ! return; /* No more room! */
- ! cp = tcp;
- }
- if ((int) cp & 7)
- { /* shouldn't happen, but just in case */
- cp = (char *) (((int) cp + 8) & ~7);
- --- 368,384 ----
- nblks = 1;
- if ((siz = nu) < 8)
- nblks = 1 << ((siz = 8) - nu);
- ! #if INGRESVER == 5 && defined(vax)
- {
- ! char *tcp;
- ! if (MEalloc(1, 1 << (siz+3), &tcp))
- ! return; /* No more room! */
- ! cp = tcp;
- }
- + #else /* INGRESVER == 5 && defined(vax) */
- + if ((cp = sbrk (1 << (siz + 3))) == (char *) -1)
- + return; /* no more room! */
- + #endif /* INGRESVER == 5 && defined(vax) */
- if ((int) cp & 7)
- { /* shouldn't happen, but just in case */
- cp = (char *) (((int) cp + 8) & ~7);
- *** /site/mar/moira/server/meinitlst.c Mon Mar 19 15:44:47 1990
- --- server/meinitlst.c Fri Apr 6 17:10:19 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.2 88/09/13 17:40:40 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.3 90/04/04 18:28:50 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- ***************
- *** 9,25 ****
- *
- * This code is a reverse-engineered version of
- * ~rtingres/lib/compatlib(meinitlst.o) with a better malloc and
- ! * free.
- */
-
- #ifndef lint
- ! static char *rcsid_meinitlst_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.2 88/09/13 17:40:40 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- #include <sys/errno.h>
- #include <sys/types.h>
-
- /*
- * entry points:
- * MEinitLists()
- --- 9,28 ----
- *
- * This code is a reverse-engineered version of
- * ~rtingres/lib/compatlib(meinitlst.o) with a better malloc and
- ! * free. It only works with Ingres version 5 on the vax.
- */
-
- #ifndef lint
- ! static char *rcsid_meinitlst_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/meinitlst.c,v 1.3 90/04/04 18:28:50 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- #include <sys/errno.h>
- #include <sys/types.h>
- + #include <moira_site.h>
-
- + #if INGRESVER == 5 && defined(vax)
- +
- /*
- * entry points:
- * MEinitLists()
- ***************
- *** 87,94 ****
- (void) free(adr);
- return new_addr;
- }
- ! #endif notdef
- ! #ifdef notdef
- valloc(size)
- int size;
- {
- --- 90,96 ----
- (void) free(adr);
- return new_addr;
- }
- !
- valloc(size)
- int size;
- {
- ***************
- *** 167,169 ****
- --- 169,172 ----
- _memalign+e3: ret
- */
- #endif notdef
- + #endif /* INGRESVER == 5 && defined(vax) */
- *** /site/mar/moira/server/Makefile Mon Mar 19 20:51:28 1990
- --- server/Makefile Mon Apr 9 12:38:48 1990
- ***************
- *** 1,6 ****
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v $
- # $Author: mar $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v 1.16 90/03/19 20:51:19 mar Exp $
- #
-
- CFILES = startmoira.c mr_main.c mr_sauth.c mr_scall.c \
- --- 1,6 ----
- # $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v $
- # $Author: mar $
- ! # $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/Makefile,v 1.17 90/04/09 12:38:30 mar Exp $
- #
-
- CFILES = startmoira.c mr_main.c mr_sauth.c mr_scall.c \
- ***************
- *** 13,24 ****
- mr_smalloc.o meinitlst.o increment.o cache.o
-
- GLUOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
- ! ../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o \
- ../rpc/krb_et.o mr_util.o increment.o cache.o
-
- GLUPOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
- ! ../../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o \
- ! ../../rpc/krb_et.o mr_util.o increment.o cache.o
-
-
- LIBS=../rpc/libmoira.a ../gdb/libgdb.a
- --- 13,25 ----
- mr_smalloc.o meinitlst.o increment.o cache.o
-
- GLUOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
- ! ../rpc/mr_et.o mr_srvdata.o mr_smalloc.o meinitlst.o mr_sbrk.o \
- ../rpc/krb_et.o mr_util.o increment.o cache.o
-
- GLUPOBJS=mr_glue.o qrtn.o queries2.o qsupport.o qsubs.o \
- ! ../../rpc/profiled/mr_et.o mr_srvdata.o mr_smalloc.o \
- ! meinitlst.o mr_sbrk.o ../../rpc/profiled/krb_et.o mr_util.o \
- ! increment.o cache.o
-
-
- LIBS=../rpc/libmoira.a ../gdb/libgdb.a
- *** /site/mar/moira/server/qrtn.qc Mon Mar 19 15:42:32 1990
- --- server/qrtn.qc Mon Apr 9 12:39:29 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.39 90/03/19 15:42:27 mar Exp $
- *
- * Copyright (C) 1987, 1988 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.42 90/04/09 12:39:09 mar Exp $
- *
- * Copyright (C) 1987, 1988 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- ***************
- *** 10,16 ****
- */
-
- #ifndef lint
- ! static char *rcsid_qrtn_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.39 90/03/19 15:42:27 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 10,16 ----
- */
-
- #ifndef lint
- ! static char *rcsid_qrtn_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qrtn.qc,v 1.42 90/04/09 12:39:09 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 29,34 ****
- --- 29,35 ----
- #define INGRES_BAD_DATE 4302
- #define INGRES_DEADLOCK 4700
- #define INGRES_TIMEOUT 4702
- + #define INGRES_NO_RANGE 2109
-
- /*
- * ingerr: (supposedly) called when Ingres indicates an error.
- ***************
- *** 56,61 ****
- --- 57,66 ----
- mr_errcode = MR_BUSY;
- com_err(whoami, 0, "timed out getting lock");
- break;
- + case INGRES_NO_RANGE:
- + mr_errcode = MR_INGRES_SOFTFAIL;
- + com_err(whoami, 0, "INGRES missing range statement");
- + break;
- default:
- mr_errcode = MR_INGRES_ERR;
- com_err(whoami, MR_INGRES_ERR, " code %d\n", *num);
- ***************
- *** 798,804 ****
- * owns. Sets the kerberos ID and user ID.
- */
-
- ! set_krb_mapping(name, login, ok, kid, uid)
- char *name;
- char *login;
- int ok;
- --- 803,809 ----
- * owns. Sets the kerberos ID and user ID.
- */
-
- ! int set_krb_mapping(name, login, ok, kid, uid)
- char *name;
- char *login;
- int ok;
- ***************
- *** 815,825 ****
- ## repeat retrieve (u_id = krbmap.#users_id, k_id = krbmap.#string_id)
- ## where krbmap.string_id = strings.string_id and strings.string = @krbname
- ## inquire_equel (rowcount = "rowcount")
-
- if (rowcount == 1) {
- *kid = -k_id;
- *uid = u_id;
- ! return;
- }
-
- if (name_to_id(name, "STRINGS", &k_id) == MR_SUCCESS)
- --- 820,831 ----
- ## repeat retrieve (u_id = krbmap.#users_id, k_id = krbmap.#string_id)
- ## where krbmap.string_id = strings.string_id and strings.string = @krbname
- ## inquire_equel (rowcount = "rowcount")
- + if (ingres_errno) return(mr_errcode);
-
- if (rowcount == 1) {
- *kid = -k_id;
- *uid = u_id;
- ! return(MR_SUCCESS);
- }
-
- if (name_to_id(name, "STRINGS", &k_id) == MR_SUCCESS)
- ***************
- *** 827,833 ****
-
- if (!ok) {
- *uid = *kid;
- ! return;
- }
-
- if (name_to_id(login, "USERS", uid) != MR_SUCCESS)
- --- 833,839 ----
-
- if (!ok) {
- *uid = *kid;
- ! return(MR_SUCCESS);
- }
-
- if (name_to_id(login, "USERS", uid) != MR_SUCCESS)
- ***************
- *** 835,840 ****
- --- 841,848 ----
-
- if (*kid == 0)
- *kid = *uid;
- + if (ingres_errno) return(mr_errcode);
- + return(MR_SUCCESS);
- ##}
-
-
- *** /site/mar/moira/server/qsupport.qc Mon Mar 19 15:43:04 1990
- --- server/qsupport.qc Mon Apr 9 21:49:04 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.49 90/03/19 15:42:34 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.52 90/04/09 19:23:04 mar Exp $
- *
- * Copyright (C) 1987 by the Massachusetts Institute of Technology
- * For copying and distribution information, please see the file
- ***************
- *** 10,16 ****
- */
-
- #ifndef lint
- ! static char *rcsid_qsupport_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.49 90/03/19 15:42:34 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 10,16 ----
- */
-
- #ifndef lint
- ! static char *rcsid_qsupport_qc = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/server/RCS/qsupport.qc,v 1.52 90/04/09 19:23:04 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 329,335 ****
- --- 329,341 ----
- client *cl;
- ##{
- ## int nuid, rowcount;
- + ## char *mit_id;
-
- + mit_id = argv[U_MITID];
- + ## retrieve (rowcount = any(u.#mit_id where u.#mit_id = mit_id))
- + if (ingres_errno) return(mr_errcode);
- + if (rowcount) return(MR_EXISTS);
- +
- if (!strcmp(argv[1], UNIQUE_UID) || atoi(argv[1]) == -1) {
- if (set_next_object_id("uid", "users"))
- return(MR_INGRES_ERR);
- ***************
- *** 660,670 ****
- setup_afil(q, argv)
- struct query *q;
- char *argv[];
- ! {
- ! char *type;
- int mach_id;
- ! char *name;
- ! char *access;
-
- type = argv[1];
- mach_id = *(int *)argv[2];
- --- 666,676 ----
- setup_afil(q, argv)
- struct query *q;
- char *argv[];
- ! ##{
- ! char *type, *name;
- int mach_id;
- ! ## int ok;
- ! ## char ftype[32], *access;
-
- type = argv[1];
- mach_id = *(int *)argv[2];
- ***************
- *** 672,682 ****
- access = argv[5];
- var_phys_id = 0;
-
- if (!strcmp(type, "NFS"))
- return (check_nfs(mach_id, name, access));
- else
- return(MR_SUCCESS);
- ! }
-
-
- /* Verify the arguments, depending on the FStype. Also, if this is an
- --- 678,694 ----
- access = argv[5];
- var_phys_id = 0;
-
- + sprintf(ftype, "fs_access_%s", type);
- + ## retrieve (ok = any(alias.trans where alias.name = ftype and
- + ## alias.type = "TYPE" and alias.trans = access))
- + if (ingres_errno) return(mr_errcode);
- + if (ok == 0) return(MR_FILESYS_ACCESS);
- +
- if (!strcmp(type, "NFS"))
- return (check_nfs(mach_id, name, access));
- else
- return(MR_SUCCESS);
- ! ##}
-
-
- /* Verify the arguments, depending on the FStype. Also, if this is an
- ***************
- *** 684,696 ****
- * the new phys_id.
- */
-
- ! setup_ufil(q, argv)
- struct query *q;
- char *argv[];
- ##{
- int mach_id, status;
- ! char *type, *name, *access;
- ! ## int fid, total;
-
- type = argv[2];
- mach_id = *(int *)argv[3];
- --- 696,710 ----
- * the new phys_id.
- */
-
- ! setup_ufil(q, argv, cl)
- struct query *q;
- char *argv[];
- + client *cl;
- ##{
- int mach_id, status;
- ! char *type, *name;
- ! ## int fid, total, who;
- ! ## char *entity, ftype[32], *access;
-
- type = argv[2];
- mach_id = *(int *)argv[3];
- ***************
- *** 698,704 ****
- --- 712,726 ----
- access = argv[6];
- var_phys_id = 0;
- fid = *(int *)argv[0];
- + who = cl->client_id;
- + entity = cl->entity;
-
- + sprintf(ftype, "fs_access_%s", type);
- + ## retrieve (total = any(alias.trans where alias.name = ftype and
- + ## alias.type = "TYPE" and alias.trans = access))
- + if (ingres_errno) return(mr_errcode);
- + if (total == 0) return(MR_FILESYS_ACCESS);
- +
- if (!strcmp(type, "NFS")) {
- status = check_nfs(mach_id, name, access);
- ## replace nfsquota (phys_id = var_phys_id) where nfsquota.filsys_id = fid
- ***************
- *** 706,718 ****
- return(status);
- } else if (!strcmp(type, "AFS")) {
- total = 0;
- ! ## retrieve (total = sum(nfsquota.quota where nfsquota.filsys_id = fid))
- if (ingres_errno) return(mr_errcode);
- if (total != 0) {
- ## delete nfsquota where nfsquota.filsys_id = fid
- if (ingres_errno) return(mr_errcode);
- ## append nfsquota (quota = total, filsys_id = fid,
- ! ## phys_id = 0, users_id = 0)
- if (ingres_errno) return(mr_errcode);
- }
- } else {
- --- 728,742 ----
- return(status);
- } else if (!strcmp(type, "AFS")) {
- total = 0;
- ! ## retrieve (total = sum(nfsquota.quota where nfsquota.filsys_id = fid
- ! ## and nfsquota.phys_id != 0))
- if (ingres_errno) return(mr_errcode);
- if (total != 0) {
- ## delete nfsquota where nfsquota.filsys_id = fid
- if (ingres_errno) return(mr_errcode);
- ## append nfsquota (quota = total, filsys_id = fid,
- ! ## phys_id = 0, users_id = 0,
- ! ## modtime = "now", modby = who, modwith = entity)
- if (ingres_errno) return(mr_errcode);
- }
- } else {
- ***************
- *** 740,749 ****
- register char *cp1;
- register char *cp2;
-
- - caccess = (isupper(*access)) ? tolower(*access) : *access;
- - if (caccess != 'r' && caccess != 'w' && caccess != 'n')
- - return(MR_FILESYS_ACCESS);
- -
- status = MR_NFS;
- ## range of np is nfsphys
- ## repeat retrieve (var_phys_id = np.#nfsphys_id, dir = trim(np.#dir))
- --- 764,769 ----
- ***************
- *** 2488,2494 ****
-
- /* find user */
- ## repeat retrieve (users_id = u.#users_id)
- ! ## where u.#uid = @uid and (u.status = 0 or u.status = 5)
- ## inquire_equel(rowcount = "rowcount");
- if (rowcount == 0)
- return(MR_NO_MATCH);
- --- 2508,2514 ----
-
- /* find user */
- ## repeat retrieve (users_id = u.#users_id)
- ! ## where u.#uid = @uid and (u.status = 0 or u.status = 5 or u.status = 6)
- ## inquire_equel(rowcount = "rowcount");
- if (rowcount == 0)
- return(MR_NO_MATCH);
- *** /site/mar/moira/clients/blanche/blanche.c Sat Mar 17 16:48:55 1990
- --- clients/blanche/blanche.c Fri Apr 6 17:01:34 1990
- ***************
- *** 1,4 ****
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.12 90/03/17 16:48:52 mar Exp $
- *
- * Command line oriented Moira List tool.
- *
- --- 1,4 ----
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.13 90/04/06 17:01:20 mar Exp $
- *
- * Command line oriented Moira List tool.
- *
- ***************
- *** 21,27 ****
- #include <moira_site.h>
-
- #ifndef LINT
- ! static char blanche_rcsid[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.12 90/03/17 16:48:52 mar Exp $";
- #endif
-
-
- --- 21,27 ----
- #include <moira_site.h>
-
- #ifndef LINT
- ! static char blanche_rcsid[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/blanche/RCS/blanche.c,v 1.13 90/04/06 17:01:20 mar Exp $";
- #endif
-
-
- ***************
- *** 182,191 ****
- }
-
- if (!noauth && (status = mr_auth("blanche"))) {
- ! com_err(whoami, status, "unable to authenticate to Moira");
- ! com_err(whoami, 0,
- ! " Try the -noauth flag if you don't need authentication");
- ! exit(2);
- }
-
- /* display list info if requested to */
- --- 182,195 ----
- }
-
- if (!noauth && (status = mr_auth("blanche"))) {
- ! if (status == MR_USER_AUTH)
- ! com_err(whoami, status, "");
- ! else {
- ! com_err(whoami, status, "unable to authenticate to Moira");
- ! com_err(whoami, 0,
- ! " Try the -noauth flag if you don't need authentication");
- ! exit(2);
- ! }
- }
-
- /* display list info if requested to */
- *** /site/mar/moira/clients/passwd/chfn.c Sat Mar 17 17:19:08 1990
- --- clients/passwd/chfn.c Mon Mar 26 05:42:35 1990
- ***************
- *** 3,15 ****
- * and distribution information, see the file "mit-copyright.h".
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.8 90/03/17 17:19:04 mar Exp $
- ! * $Author: mar $
- *
- */
-
- #ifndef lint
- ! static char *rcsid_chfn_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.8 90/03/17 17:19:04 mar Exp $";
- #endif not lint
-
- /*
- --- 3,15 ----
- * and distribution information, see the file "mit-copyright.h".
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.9 90/03/26 05:42:13 marc Exp $
- ! * $Author: marc $
- *
- */
-
- #ifndef lint
- ! static char *rcsid_chfn_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/passwd/RCS/chfn.c,v 1.9 90/03/26 05:42:13 marc Exp $";
- #endif not lint
-
- /*
- ***************
- *** 129,141 ****
-
- status = mr_connect(NULL);
- if (status) {
- ! com_err(whoami, status, " while connecting to Moira");
- exit(1);
- }
-
- status = mr_motd(&motd);
- if (status) {
- ! com_err(whoami, status, " unable to check server status");
- leave(1);
- }
- if (motd) {
- --- 129,141 ----
-
- status = mr_connect(NULL);
- if (status) {
- ! com_err(whoami, status, "while connecting to Moira");
- exit(1);
- }
-
- status = mr_motd(&motd);
- if (status) {
- ! com_err(whoami, status, "unable to check server status");
- leave(1);
- }
- if (motd) {
- ***************
- *** 146,152 ****
- status = mr_auth("chfn"); /* Don't use argv[0] - too easy to fake */
- if (status) {
- com_err(whoami, status,
- ! " while authenticating -- run \"kinit\" and try again.");
- leave(1);
- }
-
- --- 146,152 ----
- status = mr_auth("chfn"); /* Don't use argv[0] - too easy to fake */
- if (status) {
- com_err(whoami, status,
- ! "while authenticating -- run \"kinit\" and try again.");
- leave(1);
- }
-
- ***************
- *** 171,177 ****
- if (status = mr_query("get_finger_by_login", q_argc, q_argv,
- get_user_info, (char *) &old_info))
- {
- ! com_err(whoami, status, " while getting user information.");
- leave(2);
- }
-
- --- 171,177 ----
- if (status = mr_query("get_finger_by_login", q_argc, q_argv,
- get_user_info, (char *) &old_info))
- {
- ! com_err(whoami, status, "while getting user information.");
- leave(2);
- }
-
- ***************
- *** 197,203 ****
- if (status = mr_query("update_finger_by_login", q_argc, q_argv,
- scream, (char *)NULL))
- {
- ! com_err(whoami, status, " while updating finger information.");
- leave(1);
- }
-
- --- 197,203 ----
- if (status = mr_query("update_finger_by_login", q_argc, q_argv,
- scream, (char *)NULL))
- {
- ! com_err(whoami, status, "while updating finger information.");
- leave(1);
- }
-
- ***************
- *** 334,340 ****
- GETINFO("Office address (Exs: E40-342 or 2-108)",
- office_address, FALSE);
- GETINFO("Office phone (Ex: 3-1300)", office_phone, TRUE);
- ! GETINFO("MIT department (Exs: 9, Biology, Information Services",
- mit_department, FALSE);
- GETINFO("MIT year (Exs: 1989, '91, Faculty, Grad)", mit_year, FALSE);
- }
- --- 334,340 ----
- GETINFO("Office address (Exs: E40-342 or 2-108)",
- office_address, FALSE);
- GETINFO("Office phone (Ex: 3-1300)", office_phone, TRUE);
- ! GETINFO("MIT department (Exs: 9, Biology, Information Services)",
- mit_department, FALSE);
- GETINFO("MIT year (Exs: 1989, '91, Faculty, Grad)", mit_year, FALSE);
- }
- *** /site/mar/moira/clients/userreg/userreg.c Thu Mar 15 14:31:16 1990
- --- clients/userreg/userreg.c Mon Apr 9 19:09:01 1990
- ***************
- *** 2,8 ****
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v $
- * $Author: mar $
- * $Locker: $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.17 90/03/15 14:31:01 mar Exp $
- *
- * (c) Copyright 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- --- 2,8 ----
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v $
- * $Author: mar $
- * $Locker: $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.20 90/04/09 19:08:33 mar Exp $
- *
- * (c) Copyright 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- ***************
- *** 10,16 ****
- */
-
- #ifndef lint
- ! static char *rcsid_userreg_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.17 90/03/15 14:31:01 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 10,16 ----
- */
-
- #ifndef lint
- ! static char *rcsid_userreg_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/userreg.c,v 1.20 90/04/09 19:08:33 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 236,243 ****
- user_has_login = 0;
- sleep(1);
- return 0;
- - case UREG_NO_PASSWD_YET:
- case UREG_HALF_ENROLLED:
- user_is_valid = 1;
- user_has_login = 1;
- display_text_line ("You have chosen a login name, but you have not yet chosen a password.");
- --- 236,245 ----
- user_has_login = 0;
- sleep(1);
- return 0;
- case UREG_HALF_ENROLLED:
- + enrollment = 1;
- + /* fall through to: */
- + case UREG_NO_PASSWD_YET:
- user_is_valid = 1;
- user_has_login = 1;
- display_text_line ("You have chosen a login name, but you have not yet chosen a password.");
- ***************
- *** 299,304 ****
- --- 301,310 ----
- case ETIMEDOUT:
- case UREG_MISC_ERROR:
- display_text(NETWORK_DOWN);
- + display_text_line(" ");
- + sprintf(line, "The specific error was: %s",
- + error_message(result));
- + display_text_line(line);
- wait_for_user();
- return (0);
-
- ***************
- *** 587,592 ****
- --- 593,599 ----
- do_replace()
- {
- int status;
- + char buf[100];
-
- /*
- * replaces a user in the database. If there is an error, it informs
- ***************
- *** 603,608 ****
- --- 610,620 ----
- timer_on();
- if (status) {
- display_text (NETWORK_DOWN);
- + display_text_line(" ");
- + sprintf(buf, "The specific error was: %s",
- + error_message(status));
- + display_text_line(buf);
- + wait_for_user();
- return (-1);
- } else return 0;
- }
- ***************
- *** 663,670 ****
- while (p2 >= cp && isspace(*p2)) *(--p2) = '\0';
- }
- /* Make it capitalized */
- ! for (p2=cp; *p2; p2++) {
- ! if (isupper(*p2)) *p2 = tolower(*p2);
- ! }
- ! if (islower(*cp)) *cp=toupper(*cp);
- }
- --- 675,679 ----
- while (p2 >= cp && isspace(*p2)) *(--p2) = '\0';
- }
- /* Make it capitalized */
- ! FixCase(cp);
- }
- *** /site/mar/moira/clients/userreg/reg_stubs.c Sat Mar 17 17:24:37 1990
- --- clients/userreg/reg_stubs.c Mon Apr 9 14:25:27 1990
- ***************
- *** 1,7 ****
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.15 90/03/17 17:24:31 mar Exp $
- *
- * (c) Copyright 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- --- 1,7 ----
- /*
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.16 90/04/09 14:25:16 mar Exp $
- *
- * (c) Copyright 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- ***************
- *** 9,15 ****
- */
-
- #ifndef lint
- ! static char *rcsid_reg_stubs_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.15 90/03/17 17:24:31 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- --- 9,15 ----
- */
-
- #ifndef lint
- ! static char *rcsid_reg_stubs_c = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/userreg/RCS/reg_stubs.c,v 1.16 90/04/09 14:25:16 mar Exp $";
- #endif lint
-
- #include <mit-copyright.h>
- ***************
- *** 42,48 ****
- extern char *getenv(), **hes_resolve();
-
- initialize_ureg_error_table();
- !
- seq_no = getpid();
-
- host = NULL;
- --- 42,50 ----
- extern char *getenv(), **hes_resolve();
-
- initialize_ureg_error_table();
- ! initialize_krb_error_table();
- ! initialize_sms_error_table();
- !
- seq_no = getpid();
-
- host = NULL;
- *** /site/mar/moira/clients/moira/dcmmaint.c Sat Mar 17 17:10:21 1990
- --- clients/moira/dcmmaint.c Tue Mar 27 11:41:27 1990
- ***************
- *** 1,4 ****
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/dcmmaint.c,v 1.7 90/03/17 17:10:15 mar Exp $
- *
- * Copyright 1987, 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- --- 1,4 ----
- ! /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/dcmmaint.c,v 1.8 90/03/27 11:40:41 mar Exp $
- *
- * Copyright 1987, 1988 by the Massachusetts Institute of Technology.
- * For copying and distribution information, please see the file
- ***************
- *** 164,170 ****
- argv[SC_INTERVAL] = strsave("1440");
- sprintf(tmp, "/tmp/%s.out", name);
- argv[SC_TARGET] = strsave(tmp);
- ! sprintf(tmp, "/u1/mr/bin/%s.sh", name);
- argv[SC_SCRIPT] = strsave(tmp);
- argv[SC_TYPE] = strsave("UNIQUE");
- argv[SC_ENABLE] = strsave("1");
- --- 164,170 ----
- argv[SC_INTERVAL] = strsave("1440");
- sprintf(tmp, "/tmp/%s.out", name);
- argv[SC_TARGET] = strsave(tmp);
- ! sprintf(tmp, "%s/%s.sh", BIN_DIR, name);
- argv[SC_SCRIPT] = strsave(tmp);
- argv[SC_TYPE] = strsave("UNIQUE");
- argv[SC_ENABLE] = strsave("1");
- *** /site/mar/moira/clients/moira/attach.c Sat Mar 17 17:10:07 1990
- --- clients/moira/attach.c Thu Apr 5 17:36:09 1990
- ***************
- *** 1,5 ****
- #if (!defined(lint) && !defined(SABER))
- ! static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.21 90/03/17 17:09:54 mar Exp $";
- #endif
-
- /* This is the file attach.c for the MOIRA Client, which allows a nieve
- --- 1,5 ----
- #if (!defined(lint) && !defined(SABER))
- ! static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.23 90/04/05 17:35:57 mar Exp $";
- #endif
-
- /* This is the file attach.c for the MOIRA Client, which allows a nieve
- ***************
- *** 13,19 ****
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.21 90/03/17 17:09:54 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- --- 13,19 ----
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/attach.c,v 1.23 90/04/05 17:35:57 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- ***************
- *** 244,250 ****
- char ** info;
- Bool name;
- {
- ! char temp_buf[BUFSIZ], *newname;
- int fsgroup = 0;
-
- Put_message("");
- --- 244,250 ----
- char ** info;
- Bool name;
- {
- ! char temp_buf[BUFSIZ], *newname, access_type[32];
- int fsgroup = 0;
-
- Put_message("");
- ***************
- *** 276,282 ****
- if (!fsgroup) {
- GetValueFromUser("Filesystem's Pack Name", &info[FS_PACK]);
- GetValueFromUser("Filesystem's Mount Point", &info[FS_M_POINT]);
- ! GetValueFromUser("Filesystem's Default Access", &info[FS_ACCESS]);
- }
- GetValueFromUser("Comments about this Filesystem", &info[FS_COMMENTS]);
- GetValueFromUser("Filesystem's owner (user)", &info[FS_OWNER]);
- --- 276,284 ----
- if (!fsgroup) {
- GetValueFromUser("Filesystem's Pack Name", &info[FS_PACK]);
- GetValueFromUser("Filesystem's Mount Point", &info[FS_M_POINT]);
- ! sprintf(access_type, "fs_access_%s", info[FS_TYPE]);
- ! GetTypeFromUser("Filesystem's Default Access", access_type,
- ! &info[FS_ACCESS]);
- }
- GetValueFromUser("Comments about this Filesystem", &info[FS_COMMENTS]);
- GetValueFromUser("Filesystem's owner (user)", &info[FS_OWNER]);
- *** /site/mar/moira/clients/moira/menu.h Tue Dec 27 18:49:43 1988
- --- clients/moira/menu.h Mon Apr 9 18:03:14 1990
- ***************
- *** 1,3 ****
- --- 1,5 ----
- + /* $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.h,v 1.2 90/04/09 18:02:53 mar Exp $ */
- +
- #define MAX_ARGC 16 /* Maximum argument count per line */
- #define MAX_ARGLEN 128 /* Maximum length of an argument */
- #define MAX_LINES 16 /* Maximum number of lines per menu */
- ***************
- *** 40,42 ****
- --- 42,48 ----
- #define NULLMENU ((struct menu *) 0)
- #define SUBMENU(cmd, doc, menu) { NULLFUNC, menu, 1, { { cmd, doc } } }
- #define SIMPLEFUNC(cmd, doc, func) { func, NULLMENU, 1, { { cmd, doc } } }
- +
- + /* Unused words found on parsed command line */
- + extern int parsed_argc;
- + extern char **parsed_argv;
- *** /site/mar/moira/clients/moira/menu.c Sat Mar 17 17:12:09 1990
- --- clients/moira/menu.c Mon Apr 9 18:04:06 1990
- ***************
- *** 5,11 ****
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.27 90/03/17 00:19:53 mar Exp $
- *
- * Generic menu system module.
- *
- --- 5,11 ----
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.28 90/04/09 18:03:56 mar Exp $
- *
- * Generic menu system module.
- *
- ***************
- *** 18,24 ****
- */
-
- #ifndef lint
- ! static char rcsid_menu_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.27 90/03/17 00:19:53 mar Exp $";
-
- #endif lint
-
- --- 18,24 ----
- */
-
- #ifndef lint
- ! static char rcsid_menu_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/menu.c,v 1.28 90/04/09 18:03:56 mar Exp $";
-
- #endif lint
-
- ***************
- *** 63,68 ****
- --- 63,70 ----
- #define NULLMS ((struct menu_screen *) 0)
-
- Menu *top_menu; /* Root for command search */
- + int parsed_argc; /* used by extern routines to get additional */
- + char **parsed_argv; /* comand line input */
-
- /*
- * Hook function to cause error messages to be printed through
- ***************
- *** 212,221 ****
- int toggle_logging();
-
- /* Entry function gets called with old menu_screen still current */
- ! if (m->m_entry != NULLFUNC)
- if (m->m_entry(m, margc, margv) == DM_QUIT)
- return DM_NORMAL;
-
- /* The following get run only in curses mode */
- if (cur_ms != NULLMS) {
- /* Get a menu_screen */
- --- 214,230 ----
- int toggle_logging();
-
- /* Entry function gets called with old menu_screen still current */
- ! if (m->m_entry != NULLFUNC) {
- if (m->m_entry(m, margc, margv) == DM_QUIT)
- return DM_NORMAL;
- + if (parsed_argc > 0) {
- + margc = parsed_argc + 1;
- + margv = --parsed_argv;
- + }
- + }
-
- + parsed_argc = 0;
- +
- /* The following get run only in curses mode */
- if (cur_ms != NULLMS) {
- /* Get a menu_screen */
- ***************
- *** 274,295 ****
- /* This is here because we may be coming from another menu */
- if (cur_ms != NULL)
- touchwin(my_ms->ms_screen);
- ! /* Get a command */
- ! if (!Prompt_input("Command: ", buf, sizeof(buf))) {
- ! if (cur_ms == NULLMS &&
- ! feof(stdin))
- ! sprintf(buf, "quit");
- ! else
- continue;
- }
- - /* Parse it into the argument list */
- - /* If there's nothing there, try again */
- - /* Initialize argv */
- - for (argc = 0; argc < MAX_ARGC; argc++)
- - argv[argc] = argvals[argc];
- -
- - if ((argc = Parse_words(buf, argv, MAX_ARGLEN)) == 0)
- - continue;
- if ((line = atoi(argv[0])) > 0 && line <= m->m_length) {
- command = &m->m_lines[line - 1];
- }
- --- 283,314 ----
- /* This is here because we may be coming from another menu */
- if (cur_ms != NULL)
- touchwin(my_ms->ms_screen);
- ! if (margc > 1) {
- ! /* Initialize argv */
- ! for (argc = 0; argc < MAX_ARGC; argc++)
- ! argv[argc] = argvals[argc];
- ! argc = margc - 1;
- ! for (i = 1; i < margc; i++)
- ! strcpy(argvals[i - 1], margv[i]);
- ! margc = 0;
- ! } else {
- ! /* Get a command */
- ! if (!Prompt_input("Command: ", buf, sizeof(buf))) {
- ! if (cur_ms == NULLMS &&
- ! feof(stdin))
- ! sprintf(buf, "quit");
- ! else
- ! continue;
- ! }
- ! /* Parse it into the argument list */
- ! /* If there's nothing there, try again */
- ! /* Initialize argv */
- ! for (argc = 0; argc < MAX_ARGC; argc++)
- ! argv[argc] = argvals[argc];
- !
- ! if ((argc = Parse_words(buf, argv, MAX_ARGLEN)) == 0)
- continue;
- }
- if ((line = atoi(argv[0])) > 0 && line <= m->m_length) {
- command = &m->m_lines[line - 1];
- }
- ***************
- *** 349,354 ****
- --- 368,375 ----
- argvals[argc], sizeof(argvals[argc])))
- goto punt_command;
- }
- + parsed_argc = argc - command->ml_argc;
- + parsed_argv = &(argv[command->ml_argc]);
- if (command->ml_function != NULLFUNC) {
- /* If it's got a function, call it */
- quitflag = command->ml_function(argc, argv);
- ***************
- *** 368,377 ****
- }
- if (m->m_exit != NULLFUNC)
- m->m_exit(m);
- return (DM_QUIT);
- }
- punt_command:
- ! ;
- }
- }
-
- --- 389,399 ----
- }
- if (m->m_exit != NULLFUNC)
- m->m_exit(m);
- + parsed_argc = 0;
- return (DM_QUIT);
- }
- punt_command:
- ! parsed_argc = 0;
- }
- }
-
- *** /site/mar/moira/clients/moira/utils.c Sat Mar 17 17:11:39 1990
- --- clients/moira/utils.c Mon Apr 9 18:06:24 1990
- ***************
- *** 1,5 ****
- #if (!defined(lint) && !defined(SABER))
- ! static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.21 90/03/17 17:11:31 mar Exp $";
- #endif lint
-
- /* This is the file utils.c for the MOIRA Client, which allows a nieve
- --- 1,5 ----
- #if (!defined(lint) && !defined(SABER))
- ! static char rcsid_module_c[] = "$Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.25 90/04/09 18:05:03 mar Exp $";
- #endif lint
-
- /* This is the file utils.c for the MOIRA Client, which allows a nieve
- ***************
- *** 11,17 ****
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.21 90/03/17 17:11:31 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- --- 11,17 ----
- *
- * $Source: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v $
- * $Author: mar $
- ! * $Header: /afs/athena.mit.edu/astaff/project/moiradev/src/clients/moira/RCS/utils.c,v 1.25 90/04/09 18:05:03 mar Exp $
- *
- * Copyright 1988 by the Massachusetts Institute of Technology.
- *
- ***************
- *** 262,268 ****
- * Arguments: prompt - the prompt string.
- * buf, buflen - buffer to be returned and its MAX size?
- * default value for the answer.
- ! * Returns: the value returned by prompt_input.
- */
-
- int
- --- 262,268 ----
- * Arguments: prompt - the prompt string.
- * buf, buflen - buffer to be returned and its MAX size?
- * default value for the answer.
- ! * Returns: zero on failure
- */
-
- int
- ***************
- *** 274,279 ****
- --- 274,288 ----
- char tmp[BUFSIZ];
- int ans;
-
- + if (parsed_argc > 0) {
- + parsed_argc--;
- + strncpy(buf, parsed_argv[0], buflen);
- + sprintf(tmp, "%s: %s", prompt, buf);
- + Put_message(tmp);
- + parsed_argv++;
- + return(1);
- + }
- +
- (void) sprintf(tmp, "%s [%s]: ", prompt, def ? def : "");
- ans = Prompt_input(tmp, buf, buflen);
- if (ans == 0) {
- ***************
- *** 387,393 ****
- Put_message("Please use a non-empty name.");
- else if (index(s, ' '))
- Put_message("You cannot use space (' ') in this name.");
- ! else if (index(s, WILDCARD))
- Put_message("Wildcards not accepted here.");
- else
- return TRUE;
- --- 396,402 ----
- Put_message("Please use a non-empty name.");
- else if (index(s, ' '))
- Put_message("You cannot use space (' ') in this name.");
- ! else if (index(s, '*') || index(s, '?') || index(s, '['))
- Put_message("Wildcards not accepted here.");
- else
- return TRUE;
- ***************
- *** 465,471 ****
- {
- char buf[BUFSIZ];
-
- ! if (PromptWithDefault(prompt, buf, BUFSIZ, *pointer) == -1)
- return(SUB_ERROR);
-
- /*
- --- 474,480 ----
- {
- char buf[BUFSIZ];
-
- ! if (PromptWithDefault(prompt, buf, BUFSIZ, *pointer) == 0)
- return(SUB_ERROR);
-
- /*
- ***************
- *** 803,809 ****
- }
- elem = (struct qelem *) malloc(sizeof(struct qelem));
- ce = (struct cache_elem *) malloc(sizeof(struct cache_elem));
- ! ce->cache_name = tname;
- ce->cache_data = QueueTop(oelem);
- elem->q_data = (char *)ce;
- AddQueue(elem, cache);
- --- 818,824 ----
- }
- elem = (struct qelem *) malloc(sizeof(struct qelem));
- ce = (struct cache_elem *) malloc(sizeof(struct cache_elem));
- ! ce->cache_name = strsave(tname);
- ce->cache_data = QueueTop(oelem);
- elem->q_data = (char *)ce;
- AddQueue(elem, cache);
- ***************
- *** 849,856 ****
- return(GetTypeFromUser(prompt, tname, pointer));
- }
- for (elem = GetTypeValues(tname); elem; elem = elem->q_forw) {
- ! if (!cistrcmp(elem->q_data, *pointer))
- return(SUB_NORMAL);
- }
- sprintf(buffer, "\"%s\" is not a legal value for %s. Use one of:",
- *pointer, tname);
- --- 864,873 ----
- return(GetTypeFromUser(prompt, tname, pointer));
- }
- for (elem = GetTypeValues(tname); elem; elem = elem->q_forw) {
- ! if (!cistrcmp(elem->q_data, *pointer)) {
- ! strcpy(*pointer, elem->q_data);
- return(SUB_NORMAL);
- + }
- }
- sprintf(buffer, "\"%s\" is not a legal value for %s. Use one of:",
- *pointer, tname);
- ***************
- *** 865,873 ****
- argv[0] = tname;
- argv[1] = "TYPE";
- argv[2] = *pointer;
- ! for (p = argv[2]; *p; p++)
- if (islower(*p))
- ! *p = toupper(*p);
- if (stat = do_mr_query("add_alias", 3, argv, Scream, NULL)) {
- com_err(program_name, stat, " in add_alias");
- } else {
- --- 882,892 ----
- argv[0] = tname;
- argv[1] = "TYPE";
- argv[2] = *pointer;
- ! /* don't uppercase access flags. Do uppercase everything else */
- ! if (strncmp(tname, "fs_access", 9))
- ! for (p = argv[2]; *p; p++)
- if (islower(*p))
- ! *p = toupper(*p);
- if (stat = do_mr_query("add_alias", 3, argv, Scream, NULL)) {
- com_err(program_name, stat, " in add_alias");
- } else {
- *** /site/mar/moira/doc/install.mss Fri Mar 23 12:38:29 1990
- --- doc/install.mss Fri Apr 6 12:01:26 1990
- ***************
- *** 51,56 ****
- --- 51,60 ----
- for the sake of backwards compatibility. You probably don't need
- these.
-
- + Define @b(INGRESVER) to be the major version number of the Ingres
- + release you are using (i.e. 4, 5, or 6). This is used by some server
- + code which attempts to work around certain Ingres bugs.
- +
- At the end of the file are a number of defines of filenames and
- directories that the server will use. These directories are referred
- to by name below. You may change them to arrange the disk usage on
- *** /site/mar/moira/doc/install.doc Fri Mar 23 12:38:28 1990
- --- doc/install.doc Mon Apr 9 22:25:28 1990
- ***************
- *** 46,52 ****
- for the sake of backwards compatibility. You probably don't need
- these.
-
- ! 6. At the end of the file are a number of defines of filenames and
- directories that the server will use. These directories are
- referred to by name below. You may change them to arrange the disk
- usage on your Moira server differently.
- --- 46,56 ----
- for the sake of backwards compatibility. You probably don't need
- these.
-
- ! 6. Define INGRESVER to be the major version number of the Ingres
- ! release you are using (i.e. 4, 5, or 6). This is used by some
- ! server code which attempts to work around certain Ingres bugs.
- !
- ! 7. At the end of the file are a number of defines of filenames and
- directories that the server will use. These directories are
- referred to by name below. You may change them to arrange the disk
- usage on your Moira server differently.
-